Description: 数据结构中解决约瑟夫环问题的代码,里面只有源代码,大家用TC2编译一下就可以用了:)。-data structure to solve the problem of Josephus code, only the source code, we use TC2 compiler can use it with a :). Platform: |
Size: 954 |
Author:苏辉 |
Hits:
Description: 数据结构课程设计打包下载,包括两个1.约瑟夫环 2.最小生成树问题!!!我已经交给老师,发给大家参考一下-data structure course design package download, including two one. Josephus 2. The minimum spanning tree problem! ! ! I was handed over to the teachers, to your reference! ! Platform: |
Size: 8671 |
Author:xing |
Hits:
Description: 数据结构实验 循环链表josephus问题 N人围坐循环报数出列-Experimental cycle of linked list data structure problem N Josephus reported that the number of people around the circle out Platform: |
Size: 1024 |
Author:lan |
Hits:
Description: Josephus 排列问题定义如下:假设n 个竞赛者排成一个环形。给定一个正整数m,从某
个指定的第1 个人开始,沿环计数,每遇到第m 个人就让其出列,且计数继续进行下去。这
个过程一直进行到所有的人都出列为止。最后出列者为优胜者。每个人出列的次序定义了整
数1,2,…,n 的一个排列。这个排列称为一个(n,m)Josephus 排列。
例如,(7,3)Josephus 排列为3,6,2,7,5,1,4。
对于给定的1,2,…,n 中的k 个数,Josephus 想知道是否存在一个正整数m 使得
(n,m)Josephus 排列的最后k 个数恰为事先指定的这k 个数。-Josephus with the problem are defined as follows: Suppose n a player lined up a ring. Given a positive integer m, from a designated section 1 begins with individuals along the ring count, the first m individuals, when confronted by their let out, and the count continued. This process until all the listed date. Finally a column for the winners. Each person listed in the order of the definition of the integers 1,2, ..., n an order. This arrangement is called a (n, m) Josephus arranged. For example, (7,3) Josephus arranged for 3,6,2,7,5,1,4. For a given 1,2, ..., n in the k number, Josephus would like to know whether there is a positive integer m makes (n, m) Josephus with the final number of exactly k pre-designated number of this k. Platform: |
Size: 1024 |
Author:杨哲 |
Hits:
Description: 用循环单链表解决josephus问题的算法-Circular single linked list using an algorithm to solve the problem josephus Platform: |
Size: 1024 |
Author:hrx |
Hits:
Description: 编写一个求解Josephus问题的函数。用整数序列1, 2, 3, ……, n表示顺序围坐在圆桌周围的人。然后使用n = 9, s = 1, m = 5,以及n = 9, s = 1, m = 0,或者n = 9, s = 1, m = 10作为输入数据,检查你的程序的正 确性和健壮性。最后分析所完成算法的时间复杂度。定义JosephusCircle类,其中含完成初始化、报数出圈成 员函数、输出显示等方法。-Josephus write a problem solving function. With the sequence of integers 1, 2, 3, ... ..., n the order of sitting around the round table, said the people around. And then use n = 9, s = 1, m = 5, and n = 9, s = 1, m = 0, or n = 9, s = 1, m = 10 as input data, check the correctness of your program and robustness. Completed the final analysis, the algorithm' s time complexity. Definition JosephusCircle class, which included the completion of initialization, reported that the number of member functions of a circle, the output display and other methods. Platform: |
Size: 1024 |
Author:王宗亮 |
Hits:
Description: <经典算法合集>其中包括:
最小生成树
MD5加密
LZW压缩
josephus
乘法表
积分
枚举
基数转换
矩阵问题举例
求解质数
圆周率的求法
改进的快速排序法
几种插入排序法
水仙花数
迷宫生成器
生命游戏
递归
回溯
贪心
动态规划
排序算法-" Classical algorithm Collection> These include: minimum spanning tree MD5 encryption LZW compression josephus multiplication table base transformation matrix integral enumeration problem solving prime number example, the rate of Improved Methods of the circumference of the Quick Sort Insertion Sort Narcissistic number of several maze generator recursive Game of Life dynamic programming backtracking greedy sorting algorithm Platform: |
Size: 4215808 |
Author:我很笨 |
Hits:
Description: line.c-某软件公司大约有30名员工,每名员工有姓名、工号、职务等属性,每年都有员工离职和入职。
把所有员工按照顺序存储结构建立一个线性表,建立离职和入职函数,当有员工离职或入职时,修改线性表,并且打印最新的员工名单。
Compute.cpp--约瑟夫(Josephus)环问题
8Queens.cpp--8皇后问题
4Colors.cpp--4色问题
4Fib.cpp--f0=f1=f2=0, f3=1,…,fi=fi-1+fi-2+fi-3+fi-4,
利用容量为k=4的循环队列,构造序列的前n+1项(f0, f1 , f2 ,… fn ),要求满足fn ≤200而fn+1 >200。-line.c-a software company about 30 employees, each employee has the name, work number, and rank each year, staff turnover and vacancies. All employees in accordance with the order of a linear table storage structure, the establishment of separation and entry functions, when employees leave or entry, modify the linear form, and print the latest staff list. Compute.cpp-- Joseph (Josephus) Central problems 8Queens.cpp--8 queens 4Colors.cpp--4 color problem 4Fib.cpp--f0 = f1 = f2 = 0, f3 = 1, ..., fi = fi- 1+ fi-2+ fi-3+ fi-4, with size k = 4 of the cycle for the queue, before the construction sequence n+1 items (f0, f1, f2, ... fn), required to meet the fn ≤ 200 and fn+1> 200. Platform: |
Size: 4096 |
Author:huchenzhi |
Hits:
Description: 约瑟夫环是一个数学的应用问题:已知n个人(以编号1,2,3...n分别表示)围坐在一张圆桌周围。从编号为k的人开始报数,数到m的
那个人出列 他的下一个人又从1开始报数,数到m的那个人又出列 依此规律重复下去,直到圆桌周围的人全部出列。-Josephus is the application of a mathematical problem: Given n individuals (in numbers 1,2,3 ... n, respectively) sitting around a round table around. From the number of people began to report the number of k, the number of the person out to m column his newspaper the next person and from a start number, the number to the man and the m columns so regular repeated until the round table around were all out of line. Platform: |
Size: 8278016 |
Author:Margaret |
Hits:
Description: C++链表解决约瑟夫环问题,问题描述:假设有N个小孩按照序号1,2,,,N围坐成一圈,从第一个小孩开始报数,每次报到n的人退出,接着从下一个人重新开始从1开始报数,下一次再报到n的人退出,
求最后一个留下第几个人;-C++ linked list to solve the problem Josephus, described the problem: Suppose there are N children according to number 1,2,,, N sitting in a circle, starting from the first child reported that the number of people out of every report of n, then from the next to re-start from 1 reported that the number, n, the next person and then report out, seeking the last to leave the first few people Platform: |
Size: 5040128 |
Author:沈宙 |
Hits:
Description: 用数组解JOSEPHUS问题的程序源码,绝对没有错误,很好,不错-With an array of JOSEPHUS problem of program source code, there is absolutely no wrong, is very good, good Platform: |
Size: 2048 |
Author:unitiinglatiwn |
Hits:
Description: 用数组解JOSEPHUS问题的程序源码,绝对没有错误,很好,不错-With an array of JOSEPHUS problem of program source code, there is absolutely no wrong, is very good, good Platform: |
Size: 2048 |
Author:Eliine |
Hits:
Description: 这是一个Josephus问题的C++代码,用双向链表实现,很好-This is a c++ code, Josephus problem with two-way linked list implementation, is very good Platform: |
Size: 2048 |
Author:iitm_170078 |
Hits:
Description: 约瑟夫环问题源代码
约瑟夫环(约瑟夫问题)是一个数学的应用问题:已知n个人(以编号1,2,3...n分别表示)围坐在一张圆桌周围。从编号为k的人开始报数,数到m的那个人出列 他的下一个人又从1开始报数,数到m的那个人又出列 依此规律重复下去,直到圆桌周围的人全部出列。通常解决这类问题时我们把编号从0~n-1,最后结果+1即为原问题的解。-Joseph ring problem source code
Joseph s ring (Joseph s problem) is a mathematical application problem: the known n individuals (in Numbers 1, 2, 3... n) sit around a round table. The number of people who have been numbered by the number of people who have been numbered by k is going to be in the column His next one starts at one, and the one who counts to m is out again. Repeat this pattern until all the people around the round table go out. And usually when we solve this problem we re going to go 0 to n minus 1, and then we re going to solve for the original problem.
Platform: |
Size: 791552 |
Author:苗 |
Hits:
Description: 这是一个Josephus问题的C++代码,用双向链表实现,很好(This is a c + + code, Josephus problem with two-way linked list implementation, is very good) Platform: |
Size: 1024 |
Author:peccmqositiqn
|
Hits:
Description: 用数组解JOSEPHUS问题的程序源码,绝对没有错误,很好,不错(With an array of JOSEPHUS problem of program source code, there is absolutely no wrong, is very good, good) Platform: |
Size: 2048 |
Author:bquatizn
|
Hits:
Description: 包含了线性表、栈、队列、二叉树、查找排序等多个内容,还实现了约瑟夫斯问题。(It includes many contents such as linear table, stack, queue, two fork tree, search sort and so on. The Josephus problem is also realized.) Platform: |
Size: 4711424 |
Author:Ccc_J罗
|
Hits: